<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
          "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
          
<html xmlns="http://www.w3.org/1999/xhtml" 
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:f="http://java.sun.com/jsf/core" 
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:t="http://myfaces.apache.org/tomahawk">
<body>
 	<!-- common menu for all pages -->
 	<ui:composition >
 		<div style="overflow:auto; width:100%; height:200px">
			<t:dataTable styleClass="items"
						 headerClass="itemsHeader"
						 rowClasses="evenRow,oddRow"
						 border="1" binding="#{manageUsersBean.dataTable}" value="#{manageUsersBean.userList}" var="user">
				<t:column id="user_id">
						<f:facet name="header">
							<t:outputText value=" User ID" />
		      			</f:facet>
						<t:outputText value="#{user.id}" />
				</t:column>
				<t:column id="user_name">
						<f:facet name="header">
							<t:outputText value=" User Name" />
		      			</f:facet>
						<t:outputText value="#{user.name}" />
				</t:column>
				<t:column rendered="#{manageUsersBean.isRendered}">
						<f:facet name="header">
							<t:outputText value=" Edit User" />
		      			</f:facet>
						<t:commandLink value="edit user" action="#{manageUsersBean.displayUser}" />
				</t:column>
				<t:column rendered="#{manageUsersBean.isRendered}">
						<f:facet name="header">
							<t:outputText value=" Delete User" />
		      			</f:facet>
						<t:commandLink value="delete user" action="#{manageUsersBean.deleteRegisteredUser}" />	
				</t:column>
			</t:dataTable>
		</div>	

   </ui:composition>
</body>
 </html>